1. Field of the Invention
The present invention relates to a code reading apparatus and a computer program product.
2. Background Art
Conventionally, there is known a code reading apparatus which decodes a symbol such as a one-dimensional barcode or a two-dimensional code to obtain information. In the code reading apparatus, a two-dimensional imager device is installed. The two-dimensional imager device optically picks up (captures) an image of a symbol, and decodes the symbol based on the picked-up image so as to obtain data.
In recent years, such a code reading apparatus uses a liquid lens which is small and light and can change its focal distance (focal length) at high speed, as disclosed by Japanese Patent Application Laid-Open Publication No. 2010-182057, for example. The focal distance of the liquid lens is changed by applying an applied voltage to the liquid lens. Consequently, the code reading apparatus need not have a drive component such as a motor, and durability thereof increases, accordingly.
Furthermore, various technologies have been developed, the technologies by which a symbol as a reading subject for a code reading apparatus is automatically and accurately brought into focus with a liquid lens. For example, Japanese Patent Application Laid-Open Publication No. 2010-262247 discloses a technology by which the focus of a liquid lens is accurately maintained on a reading subject by obtaining a relationship between the applied voltage to the liquid lens and the focal distance thereof in advance and keeping a table of the obtained relationship, and also keeping a correction table for the applied voltage, the correction table being created by taking the influence of the ambient temperature of the liquid lens into account.
However, a liquid lens has a problem that the properties of liquids thereof gradually change. Consequently, the relationship between the focal distance of a liquid lens and the applied voltage thereto changes as time passes. Therefore, when a table of the initial relationship between the focal distance and the applied voltage is kept and used, a problem arises that as time passes, the focus of the liquid lens cannot be maintained on a reading subject, little by little.